Literals
Literals in VectorScript are data values that appear directly within the script code. Literals can be numbers, text strings, the Boolean values TRUE and FALSE, or the special value NIL. The following subsections describe each literal type.
Integer Literals
Integer values in VectorScript are represented as a sequence of digits with an optional minus sign prepending the sequence (for negative values).
 
Floating-point Literals
Floating-point values may be represented using either the traditional decimal point notation or by using exponential (scientific) notation.
A floating-point value in decimal format is represented as:
*
*
*
A floating-point value in exponential notation is represented as:
*
*
*
*
*
*
 
VectorScript also allows you to use dimensional notation with numeric literals and values, and will recognize common dimensional symbols for units such as feet, inches, or meters. See Units and Numeric Values in Scripts for details on how to use numeric literals with dimensional notation.
String Literals
Strings literals are any sequence of zero or more characters enclosed within single quotes. They are represented using the following rules:
*
*
*
*
*
*
 
Boolean Literals
Boolean literals in VectorScript represent a “truth value” (whether something is true or false). Most comparison operations in VectorScript yield a Boolean value that indicates whether the operation succeeded or failed. Since there are two possible truth states, there are two Boolean literals in VectorScript: the keywords TRUE and FALSE.
The NIL Literal
The last literal type in VectorScript is a specialized literal, the NIL literal. Other literals in VectorScript represent a particular type of data. The NIL literal is different—it represents a lack of value. In a sense, NIL is like zero for data types other than numbers. NIL is usually associated with the HANDLE data type, where its use indicates that no handle exists.

Lexical Structures of VectorScript : Literals

Nemetschek NA
Phone: 410.290.5114
Fax: 410.290.8050